package com.longli.tank.strategy;

import com.longli.tank.*;

public class DefaultFireStrategy implements FireStrategy{
    @Override
    public void fire(Player player) {
        int bx=player.getX()+ ResourceMgr.goodTankL.getWidth()/2-ResourceMgr.bulletL.getWidth()/2;
        int by=player.getY()+ResourceMgr.goodTankL.getHeight()/2-ResourceMgr.bulletL.getHeight()/2;
        TankFrame.INSTANCE.add(new Bullet(bx,by,player.getDir(),player.getGroup()));
    }
}
